import Vue from 'vue'
import Vuex from 'vuex'

Vue.use(Vuex)

export default new Vuex.Store({
  state: {
    btn:false
  },
  mutations: {
    setbtn(state,msg){
      console.log(state)
      console.log(msg)
      console.log('vuexset调用')
      state.btn = msg
      console.log(state.btn)
    }
  },
  getters:{
    getbtn: state => {
      console.log('vuexget调用')
      console.log(state.btn)
      return state.btn
    }
  },
  actions: {
  },
  modules: {
  }
})
